"use strict"

var gets = function(dom) {
    return document.querySelector(dom);
};

var h1 = gets("h1");
var swap1 = h1.innerText.split("");
for (var i in swap1) {
    swap1[i] = "<font>"+swap1[i]+"</font>";
}

var s1 = swap1.join("");
h1.innerHTML = s1;
var h1 = document.querySelectorAll("h1 font");
console.log(h1);

function GetRandomNum(Min,Max)
{   
    var Range = Max - Min;   
    var Rand = Math.random();   
    return(Min + Math.round(Rand * Range));   
} 

var swap = setInterval(function() {
    for (var once = 0; once < 10; once++) {
        h1[once].style.cssText = "color: rgb("+ (GetRandomNum(0,255)) +", "+(GetRandomNum(0,255))+","+(GetRandomNum(0,255))+");";
    }
}, 60);